#ifndef BORROWER_T_H
#define BORROWER_T_H

#include <string>
#include <list>

using namespace std;

typedef long id_t;
class Book_t;

class Borrower_t {

	friend ostream &operator<< (ostream& os, const Borrower_t & borrower);

private:
	Borrower_t(const Borrower_t & borrower); // copying a borrower is unavailable... because copying people doesn't make any sense...
	Borrower_t & operator= (const Borrower_t & borrower); // assignment of borrower is unavailable too

	string name_;
	id_t id_;

	list<const Book_t *> borrowed_books_;

public:

	~Borrower_t() {};
	Borrower_t(const string & name, const id_t & id) \
		: name_(name), id_(id) {};


	inline const string & getName() const { return name_; }
	inline const id_t & getId() const { return id_; }

	inline const int getNumOfBorrowedBooks() const {return borrowed_books_.size();};

	void borrowBook(const Book_t * book);
	void returnBook(const Book_t * book);
};

#endif